import java.util.Scanner;

/**
 * @author Zy
 */
public class Fb {

    protected static int f(int n){
        if(n<=1) {
            return 1;
        }
        return f(n-1)+f(n-2);
    }
    
    public static void main(String[] args) {
        int j = 100;
        for (int i = 0; i < j; i++) {
            System.out.println("递归结果为："+f(i));
            Scanner scanner = new Scanner(System.in);
            System.out.print("请输入：");
            int i1 = scanner.nextInt();
            if (i1 >5){
                System.out.println("结束");
                break;
            }
        }
    }

}


